.remote
  = form_for(@user, url: change_password_user_path(@user), html: one_submit_only, remote: true) do |f|
    = link_to_close password_user_path(@user)

    = f.error_messages object_name: t('password')

    .section
      %table
        %tr
          %td
            .label.req.top #{t :current_password}:
            = password_field_tag :current_password, nil
          %td{ colspan: 2 }= spacer
        %tr
          %td
            .label.req #{t :new_password}:
            = f.password_field :password
          %td= spacer
          %td
            .label.req #{t :password_confirmation}:
            = f.password_field :password_confirmation

    .buttonbar
      = f.submit t(:change_password)
      #{t :or}
      = link_to_cancel password_user_path(@user)
%br
